/**
 * 公共的增删改查方法
 */
publicCurdAjax={
    //模块
    model :'',
    //链接
    //主键
    source:'',
    //增加记录
    Add:function () {
        
        $.ajax({
            type: "post",
            url: '/'+this.model+"/c/"+this.source,
            dataType: 'JSON',
            
            success:function(data){
                
            },error:function(){
            },
            complete:function(XMLHttpRequest,textStatus,errorThrown){
            }
        })
    },
    //删除单条记录
    Del:function () {
        
        $.ajax({
            type: "post",
            url: '/'+this.model+"/del/"+this.source,
            dataType: 'JSON',
            
            success:function(data){
                
            },error:function(){
            },
            complete:function(XMLHttpRequest,textStatus,errorThrown){
            }
        })
    },
    //批量删除记录
    DelAll:function () {
        
        $.ajax({
            type: "post",
            url: '/'+this.model+"/delAll/"+this.source,
            dataType: 'JSON',
            async: false,
            success:function(data){
                
            },error:function(){
            },
            complete:function(XMLHttpRequest,textStatus,errorThrown){
            }
        })
    },
    
}
